package com.yanqu.road.entity.enums.activity.jiuzhou;

import java.util.Arrays;
import java.util.List;

/**
 * 九州棋局技能类型
 */
public enum eJiuZhouSkillType {

    Skill1(1, eJiuZhouBigSkillType.Skill1, Arrays.asList(eJiuZhouSkillEffectType.BeforeChoose), "辰星"),
    Skill2(2, eJiuZhouBigSkillType.Skill1, Arrays.asList(eJiuZhouSkillEffectType.BeforeChoose), "岁星"),
    Skill3(3, eJiuZhouBigSkillType.Skill1, Arrays.asList(eJiuZhouSkillEffectType.BeforeChoose), "镇星"),
    Skill4(4, eJiuZhouBigSkillType.Skill1, Arrays.asList(eJiuZhouSkillEffectType.BeforeChoose), "太白"),
    Skill5(5, eJiuZhouBigSkillType.Skill1, Arrays.asList(eJiuZhouSkillEffectType.BeforeChoose), "荧惑"),
    Skill6(6, eJiuZhouBigSkillType.Skill1, Arrays.asList(eJiuZhouSkillEffectType.BeforeChoose), "五行均衡"),

    Skill11(11, eJiuZhouBigSkillType.Skill2, Arrays.asList(eJiuZhouSkillEffectType.BeforeChoose), "梅花谱"),
    Skill12(12, eJiuZhouBigSkillType.Skill2, Arrays.asList(eJiuZhouSkillEffectType.BeforeChoose), "弈旨"),
    Skill13(13, eJiuZhouBigSkillType.Skill2, Arrays.asList(eJiuZhouSkillEffectType.BeforeChoose), "湖涯集"),
    Skill14(14, eJiuZhouBigSkillType.Skill2, Arrays.asList(eJiuZhouSkillEffectType.BeforeChoose), "烂柯神机"),
    Skill15(15, eJiuZhouBigSkillType.Skill2, Arrays.asList(eJiuZhouSkillEffectType.BeforeChoose, eJiuZhouSkillEffectType.BeforeAttack), "忘忧集"),

    Skill101(101, eJiuZhouBigSkillType.Skill3, Arrays.asList(eJiuZhouSkillEffectType.BeforeBattle), "步步为营·士"),
    Skill102(102, eJiuZhouBigSkillType.Skill3, Arrays.asList(eJiuZhouSkillEffectType.BeforeBattle), "步步为营·农"),
    Skill103(103, eJiuZhouBigSkillType.Skill3, Arrays.asList(eJiuZhouSkillEffectType.BeforeBattle), "步步为营·工"),
    Skill104(104, eJiuZhouBigSkillType.Skill3, Arrays.asList(eJiuZhouSkillEffectType.BeforeBattle), "步步为营·商"),
    Skill105(105, eJiuZhouBigSkillType.Skill3, Arrays.asList(eJiuZhouSkillEffectType.BeforeBattle), "步步为营·侠"),
    Skill106(106, eJiuZhouBigSkillType.Skill3, Arrays.asList(eJiuZhouSkillEffectType.BeforeRound), "愈战愈勇"),
    Skill107(107, eJiuZhouBigSkillType.Skill3, Arrays.asList(eJiuZhouSkillEffectType.BeforeBattle), "釜底抽薪"),
    Skill108(108, eJiuZhouBigSkillType.Skill3, Arrays.asList(eJiuZhouSkillEffectType.BeforeBattle), "避实击虚"),
    Skill109(109, eJiuZhouBigSkillType.Skill3, Arrays.asList(eJiuZhouSkillEffectType.BeforeBattle), "以势压人"),
    Skill110(110, eJiuZhouBigSkillType.Skill3, Arrays.asList(eJiuZhouSkillEffectType.BeforeRound, eJiuZhouSkillEffectType.BeforeAttack, eJiuZhouSkillEffectType.AfterAttack), "无懈可击"),
    Skill111(111, eJiuZhouBigSkillType.Skill3, Arrays.asList(eJiuZhouSkillEffectType.BeforeBattle, eJiuZhouSkillEffectType.AfterRound), "避其锋芒"),
    Skill112(112, eJiuZhouBigSkillType.Skill3, Arrays.asList(eJiuZhouSkillEffectType.BeforeBattle), "养精蓄锐"),
    Skill113(113, eJiuZhouBigSkillType.Skill3, Arrays.asList(eJiuZhouSkillEffectType.BeforeBattle), "坚不可摧"),
    Skill114(114, eJiuZhouBigSkillType.Skill3, Arrays.asList(eJiuZhouSkillEffectType.HpChange), "生生不息"),
    Skill115(115, eJiuZhouBigSkillType.Skill3, Arrays.asList(eJiuZhouSkillEffectType.BeforeAttack, eJiuZhouSkillEffectType.AfterAttack), "调虎离山"),
    Skill116(116, eJiuZhouBigSkillType.Skill3, Arrays.asList(eJiuZhouSkillEffectType.BeforeBattle, eJiuZhouSkillEffectType.HpChange), "金蝉脱壳"),
    Skill117(117, eJiuZhouBigSkillType.Skill3, Arrays.asList(eJiuZhouSkillEffectType.BeforeAttack, eJiuZhouSkillEffectType.AfterAttack), "乘胜追击"),
    Skill118(118, eJiuZhouBigSkillType.Skill3, Arrays.asList(eJiuZhouSkillEffectType.BeforeBattle, eJiuZhouSkillEffectType.BeforeAttack, eJiuZhouSkillEffectType.AfterAttack), "出奇制胜"),
    Skill119(119, eJiuZhouBigSkillType.Skill3, Arrays.asList(eJiuZhouSkillEffectType.BeforeAttack, eJiuZhouSkillEffectType.AfterAttack), "势如破竹"),
    Skill120(120, eJiuZhouBigSkillType.Skill3, Arrays.asList(eJiuZhouSkillEffectType.BeforeBattle, eJiuZhouSkillEffectType.HpChange), "弃子谋活"),
    Skill121(121, eJiuZhouBigSkillType.Skill3, Arrays.asList(eJiuZhouSkillEffectType.BeforeBattle), "背水一战"),
    Skill122(122, eJiuZhouBigSkillType.Skill3, Arrays.asList(eJiuZhouSkillEffectType.BeforeBattle), "听天由命"),
    Skill401(401, eJiuZhouBigSkillType.Skill4, Arrays.asList(eJiuZhouSkillEffectType.BeforeChoose), "士气高昂"),

    ;

    private int skillId;

    /**
     * 技能大类
     */
    private eJiuZhouBigSkillType bigSkillType;

    /**
     * 触发时间条件
     */
    private List<eJiuZhouSkillEffectType> effectTypeList;


    private String name;

    public String getName() {
        return name;
    }

    public int getSkillId() {
        return skillId;
    }

    public eJiuZhouBigSkillType getBigSkillType() {
        return bigSkillType;
    }

    public List<eJiuZhouSkillEffectType> getEffectTypeList() {
        return effectTypeList;
    }

    eJiuZhouSkillType(int skillId, eJiuZhouBigSkillType bigSkillType, List<eJiuZhouSkillEffectType> effectTypeList, String name) {
        this.skillId = skillId;
        this.bigSkillType = bigSkillType;
        this.effectTypeList = effectTypeList;
        this.name = name;
    }

    public static eJiuZhouSkillType forSkillId(int skillId) {
        for (eJiuZhouSkillType type : eJiuZhouSkillType.values()) {
            if (type.skillId == skillId) {
                return type;
            }
        }
        return null;
    }
}
